<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>模拟时钟</title>
</head>
<body onload=checkTime()>
	<h1>模拟时钟</h1><hr>
	<script type="text/javascript">
		var now, hour, minute, second;
		var timer, degreeHour, degreeMinute, degreeSecond;
		var stepDegree = 6;
		var stepDegreeHour = 30;
		
		function checkTime() {
			//if(document.all) {
				now = new Date();
				hour = now.getHours;
				minute = now.getMinutes;
				second = now.getSeconds;
				if(hour>12)
					hour = hour - 12;
				spinIt()
					timer = setTimeout("checkTime()", 200);
			//}
		}
		
		function spinIt() {
			window.status = hour;
			secondObj.SetIdentity();
			minuteObj.SetIdentity();
			hourObj.SetIdentity();
			
			degreeHour = 180 + stepDegreeHour * hour + Math.floor(stepDegree * minute / 12);
			degreeMinute = 180 + stepDegree * minute;
			degreeSecond = 180 + stepDegree * second;
			
			hourObj.Rotate(0, 0, degreeHour);
			minuteObj.Rotate(0, 0, degreeMinute);
			secondObj.Rotate(0, 0, degreeSecond);
		}
	</script>
	<div style="left: 340px; position: absolute; top: 100px;">
	<div style="left: 0px; position: absolute; top: 0px;">
		<OBJECT classid=CLSID:369303C2-D7AC-11D0-89D5-00A0C90833E6  height=14 id=secondObj style="HEIGHT: 120px; WIDTH: 100px;" width=14>
			<PARAM name="HighQuality" value="1">
			<PARAM name="Line0001" value="SetFillStyle(1)">	
			<PARAM name="Line0002" value="SetLineColor(80, 20, 20)">	
			<PARAM name="Line0003" value="SetFillColor(80, 20, 20)">
			<PARAM name="Line0004" value="Rect(0, 0, 1, 32)">
		</OBJECT>
	</div>
	<div style="left: 0px; position: absolute; top: 0px;">
		<OBJECT classid=CLSID:369303C2-D7AC-11D0-89D5-00A0C90833E6  height=14 id=minuteObj style="HEIGHT: 120px; WIDTH: 100px;" width=14>
			<PARAM name="HighQuality" value="1">
			<PARAM name="Line0001" value="SetFillStyle(1)">	
			<PARAM name="Line0002" value="SetLineColor(50, 50, 50)">	
			<PARAM name="Line0003" value="SetFillColor(50, 50, 50)">
			<PARAM name="Line0004" value="Rect(0, 0, 1, 30)">
		</OBJECT>
	</div>
	<div style="left: 0px; position: absolute; top: 0px;">
		<OBJECT classid=CLSID:369303C2-D7AC-11D0-89D5-00A0C90833E6  height=14 id=hourObj style="HEIGHT: 120px; WIDTH: 100px;" width=14>
			<PARAM name="HighQuality" value="1">
			<PARAM name="Line0001" value="SetFillStyle(1)">	
			<PARAM name="Line0002" value="SetLineColor(50, 50, 50)">	
			<PARAM name="Line0003" value="SetFillColor(50, 50, 50)">
			<PARAM name="Line0004" value="Rect(0, 0, 1, 16)">
		</OBJECT>
	</div>
	</div>
	<div style="COLOR: #444444; font-size: 8pt; left: 200px; letter-spacing: 0.6em; line-height: 200%;
	text-align: center; TOP: 20px; width: 200px;">

	</div>
</body>
</html>